package com.shop.service.impl;

import java.util.List;

import com.shop.dao.GoodsDao;
import com.shop.dao.impl.GoodsDaoImpl;
import com.shop.entity.Goods;
import com.shop.service.GoodsService;

public class GoodsServiceImpl implements GoodsService {

	private GoodsDao goodsDao = new GoodsDaoImpl();	
	@Override
	public List<Goods> getAllGoods(int pageSize,int pageNum) {
		return goodsDao.selectAllGoods(pageSize, pageNum);
	}
	@Override
	public int getAllGoodsRows() {
		
		return goodsDao.selectAllRows();
	}
	@Override
	public int deleteGoodsById(int goodsId) {
		// TODO Auto-generated method stub
		return goodsDao.deleteGoodsById(goodsId);
	}

}
